package com.wlz.behavioral.chainofresponsibility;

public class ConcreteHandler extends Handle {
    //设置击鼓传花的时间为10秒
    private final long time = 10000;

    @Override
    public void handleRequest(String flower) {
        if (getHandle()==null){
            return;
        }
        this.setFlower(flower);
        System.out.println(getHandle().getName() + "传递给下一个人 花:" + flower);
        getHandle().handleRequest(flower);

    }
}